/*
 * Created on Sep 30, 2003
 * ApproverRole
 * Local Projects Database
 * (c) 2003 eRomania Gateway Association
 *
 */
package ro.gateway.aida.usr;

/**
 * @author Mihai Postelnicu
 * ApproverRole
 *
 *  *
 */
public class ApproverRole extends EditorRole
{
      public ApproverRole()
      {
            name = "Approver";
            description = "This is a special editor, that can approve projects" +
                  "submitted by other editors";
            id = GroupRole.APPROVER_ROLE;
      }

      public int approver_roles[] =
            {
                  Perms.OBJECT_APPROVE,
                  Perms.AUTO_APPROVE
            };

      public boolean canDo( int action )
      {
            if ( super.canDo( action ) ) return true;
            for ( int i = 0; i < approver_roles.length; i++ )
            {
                  if ( approver_roles[ i ] == action ) return true;
            }
            return false;
      }

}
